package com.cn.front.controller;

import com.cn.common.pojo.ResultModel;
import com.cn.front.feign.TopAndFootFeign;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("topAndFoot")
public class TopAndFootController {
    @Autowired
    TopAndFootFeign topFeign;
    @RequestMapping("top")
    public ResultModel top(){
        return ResultModel.Data(topFeign.top().getData());
    }
    @RequestMapping("foot")
        public ResultModel foot(){
            return ResultModel.Data(topFeign.company().getData());
    }
}
